package com.chinackts.common.property;

import com.chinackts.auth.model.ProxyType;
import lombok.Data;

import javax.validation.constraints.Max;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

@Data
public class ProxyApiSelectionProperties {

    @NotNull(message = "代理类型不能为空")
    private ProxyType type;

    @NotBlank(message = "代理API不能为空")
    private String url;

    @NotNull(message = "代理权重不能为空")
    @Min(value = 1, message = "权重不能小于1")
    @Max(value = 100, message = "权重不能大于100")
    private Integer weight;

//    @NotBlank(message = "代理JSON解析公式不能为空")
    private String jsonPath;

}
